package com.example.demo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;

@Controller
public class ForwardController {

	@GetMapping("tobaidu")
	public String testRedirect() {
		return "redirect:http://www.baidu.com";
	}
	@GetMapping("toforward")
	public String testForward() {
		return "forward:zhi.jsp";//这里要加上jsp
	}
}
